Skip to content

Modernize Java idioms in WizardNewFolderMainPage - #4205

Open
deepika-u wants to merge 1 commit into
eclipse-platform:masterfrom
deepika-u:remove_redundant_return
Open

Modernize Java idioms in WizardNewFolderMainPage#4205
deepika-u wants to merge 1 commit into
eclipse-platform:masterfrom
deepika-u:remove_redundant_return

Conversation

@deepika-u

@deepika-u deepika-u commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

This change modernizes a few Java idioms in WizardNewFolderMainPage by:

  • Removing redundant return statements.
  • Replacing length() > 0 with isEmpty().
  • Use pattern matching for instanceof to simplify type checks and eliminate explicit casts.
  • Apply minor readability cleanups.

No functional or behavioral changes are intended.

@github-actions

github-actions Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Test Results

   855 files  ±0     855 suites  ±0   59m 3s ⏱️ - 1m 42s
 8 120 tests ±0   7 877 ✅ ±0  243 💤 ±0  0 ❌ ±0 
20 262 runs  ±0  19 608 ✅ ±0  654 💤 ±0  0 ❌ ±0 

Results for commit 8429098. ± Comparison against base commit 04c96e4.

♻️ This comment has been updated with latest results.

@deepika-u

Copy link
Copy Markdown
Contributor Author

@HeikoKlare - Could you take a look at this when you get some time please?

@BeckerWdf BeckerWdf left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

change looks good to me

@merks

merks commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

In general I think we should do "cleanups" via automated cleanup actions as @laeubi has automated them and not manually like this, because a manual approach looks to be a bottomless pit to me.

@HeikoKlare HeikoKlare left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, the changes look sound (except for one, where I left a specific comment). But I agree with Ed that investing time into optimizing auto-cleanups than doing manual cleanup would probably be even more valuable (though not all of these changes may be achievable with auto-cleanups).

@deepika-u
deepika-u force-pushed the remove_redundant_return branch from d72bd75 to 0caebf2 Compare July 27, 2026 09:43
@deepika-u
deepika-u force-pushed the remove_redundant_return branch from 0caebf2 to 8429098 Compare July 27, 2026 09:44
@deepika-u

deepika-u commented Jul 27, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the feedback! I agree that automated cleanups are the more scalable approach where applicable. I came across these changes while working on something else, but I'll keep this in mind for similar cleanup work going forward.

@deepika-u

Copy link
Copy Markdown
Contributor Author

Please let me know if there's anything else you'd like me to address.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants